<?php

namespace app\api\controller;

use think\Controller;
use think\Request;
use data\service\ConfigService;

class Config extends BaseApi
{
    private $service;

    protected function initialize()
    {
        parent::initialize();
        $this->service = new ConfigService();
    }

    /**
     * 保存操作
     */
    public function save(Request $request){
        $config = $request->post();
        $this->service->forSaveConfig($config);
        return $this->returnInfo(0,"保存成功!");
    }
}
